package com.java.study.provider;

import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;

import java.security.SecureRandom;
import java.util.Scanner;

@SpringBootApplication
@EnableEurekaClient
public class Application {

    public static void main(String[] args) {

//        System.out.println("等待输出启动端口~~~~");
//        Scanner scan = new Scanner(System.in);
//        String port = scan.nextLine();
        //---  我是服务中心

        SecureRandom secureRandom = new SecureRandom();

        new SpringApplicationBuilder(Application.class).properties("server.port=" + secureRandom.nextInt(20000)).run(args);
    }
}
